home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
FishMarket 1.0
/
FishMarket v1.0.iso
/
fishies
/
401-425
/
disk_424
/
med
/
programmers
/
examples
/
example5.bas
< prev
next >
Wrap
BASIC Source File
|
1992-05-06
|
713b
|
33 lines
REM This small program demonstrates
REM how to use "medplayer.library"
REM with Basic.
REM First copy "medplayer.bmap" from
REM MEDPlayerLibrary-drawer to LIBS:
LIBRARY "medplayer.library"
DECLARE FUNCTION GetPlayer& LIBRARY
DECLARE FUNCTION LoadModule&() LIBRARY
DECLARE FUNCTION GetCurrentModule&() LIBRARY
DEFLNG md,sa
PRINT "medplayer.library demonstration"
INPUT "Enter module name";x$
x& = GetPlayer&(1)
IF x& = 0 THEN PRINT "Player allocated." ELSE PRINT "Failed."
a$ = x$+CHR$(0)
sa = SADD(a$)
md = LoadModule&(sa)
PRINT "module loaded, address = ";md
CALL PlayModule(md)
PRINT "Now playing, press any key to quit."
WHILE INKEY$="":WEND
CALL FreePlayer
CALL UnLoadModule(md)
PRINT "Bye!!"
END